package com.stylefeng.guns.modular.flagglory.service.impl;

import com.stylefeng.guns.common.persistence.model.Robot;
import com.stylefeng.guns.common.persistence.dao.RobotMapper;
import com.stylefeng.guns.modular.flagglory.dao.RobotDao;
import com.stylefeng.guns.modular.flagglory.service.IRobotService;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

/**
 * <p>
 * lg_机器人 服务实现类
 * </p>
 *
 * @author stylefeng123
 * @since 2018-01-31
 */
@Service
@Transactional(rollbackFor = Exception.class)
public class RobotServiceImpl extends ServiceImpl<RobotMapper, Robot> implements IRobotService {
    @Autowired
    private RobotDao robotDao;
    public Robot getRadomRobot(Integer divisionId){
        return robotDao.selectRandomRobot(divisionId);
    }
}
